﻿<!--#include file="../Include/Config.asp"-->
<link rel="stylesheet" href="../Css/Admin.css" type="text/css" />
<script language="JavaScript" src="../Js/Form.js"></script>
<%
dim action,Link_id,Link_info,Link_name,Link_imgurl,Link_url,sql
action=request.QueryString("action")
Link_id=request.QueryString("Link_id")
call CheckNum(Link_id)
if action="edit" then
sql="select * from friendlink where Link_id="&Link_id
rs.open sql,conn,1,3
rs("Link_info")=request.Form("Link_info")
rs("Link_name")=request.Form("Link_name")
rs("Link_imgurl")=request.Form("Link_imgurl")
rs("Link_url")=request.Form("Link_url")
rs.update
call ShowAlert("修改成功！","FriendLinkAdmin.asp")
rs.close
else
sql="select * from FriendLink where Link_id="&Link_id
rs.open sql,conn,1,3
Link_info=rs("Link_info")
Link_name=rs("Link_name")
Link_imgurl=rs("Link_imgurl")
Link_url=rs("Link_url")
Link_id=rs("Link_id")
rs.close
%>
<form method="post" name="form1" action="?action=edit&Link_id=<%=Link_id%>" onsubmit="return CheckAdminRegForm();">
<table width="585" border="0" cellspacing="0" cellpadding="0" class="table">
  <tr>
    <th width="179">链接编辑</th>
    <th width="422">&nbsp;</th>
    <th width="374">&nbsp;</th>
  </tr>
  <tr>
    <td width="179">链接地址:</td>
    <td width="422"><input type="text" name="Link_url" size="30" value="<%=Link_url%>"></td>
    <td width="374">*必填项目，请以http://开关</td>
  </tr>
  <tr>
    <td>链接名称:</td>
    <td><input type="text" name="Link_name" size="15" value="<%=Link_name%>"/></td>
    <td>*必填项目</td>
  </tr>
  <tr>
    <td>网站LOGO地址:</td>
    <td><input name="Link_imgurl" size="30" value="<%=Link_imgurl%>"/></td>
    <td>*必填项目</td>
  </tr>
  <tr>
    <td>链接备注:</td>
    <td><textarea name="Link_info" cols="40" rows="4"><%=Link_info%></textarea></td>
    <td>*链接备注</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td><div id="button"><input name="submit"  type="submit"value="编辑"/><input name="reset" type="reset" value="重置"/></div></td>
    <td>&nbsp;</td>
  </tr>
</table>
</form>
<%end if%>
